package com.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import com.entity.User;
import com.service.userService;

@Controller

public class userController {
@Autowired
userService  userservice;
@RequestMapping("login")
public String login(String userName,String userPassword) {
User user=userservice.devlogin(userName, userPassword);
if(user!=null) {
	return "developer/main";
}
return "developer/login";
}

@RequestMapping("/tologin")
public String tologin() {
	System.err.println("123");
	return "developer/login";
}
}
